﻿using System;
using System.Collections.Generic;
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Linq;
using Tong;
using JModel;

public partial class aspnet_testPargrameDir_site_Member_Me : System.Web.UI.Page
{
    public string str = "";
    /// <summary>
    /// 當前顯示的id
    /// </summary>
    string id = "1";

    /// <summary>
    /// 用於顯示資料
    /// </summary>
    public Tong.TongUse TextData = new Tong.TongUse();

    /// <summary>
    /// 系统安装绝对路径
    /// </summary>
    public string Abs_Path = TongUse.SysPath;
    /// <summary>
    /// 用户存放数据的临时表
    /// </summary>
    DataTable MyDt = new DataTable();

    public string ho = "";

    /// <summary>
    /// 站点通用方法类
    /// </summary>
    public Tong.ThisSiteUse.SiteTong TextThisSite = new Tong.ThisSiteUse.SiteTong();


    //得到传入的栏目ID
    public String CloumnID = "1";

    /// <summary>
    /// 顯示當前欄目的簡介
    /// </summary>
    public string str1 = "";
    /// <summary>
    /// 資料表
    /// </summary>
    DataTable NewDt = new DataTable();
    /// <summary>
    /// 用于分頁的對像
    /// </summary>
    Tong.Fy.FenYe FY = new Tong.Fy.FenYe();
    /// <summary>
    /// 
    /// </summary>
    public string sud = "";

    /// <summary>
    /// 標題
    /// </summary>
    public string title = "";
    /// <summary>
    /// 表名
    /// </summary>
    public string tab = "Sys_WangZhanDeTue3aae";
    /// <summary>
    /// 学生实体
    /// </summary>
    public CX_Student stud = null;

    protected void Page_Load(object sender, EventArgs e)
    {

        LoadData();

        DataBind();

    }

    /// <summary>
    /// 帮定ID
    /// </summary>
    void DataBind()
    {
        string id = Request["id"];
        id = string.IsNullOrEmpty(id) ? "1" : id;

        NewDt = TextData.SqlataSet("select * from [" + tab + "] where [" + tab + "_id]=" + id).Tables[0];
        str = NewDt.Rows[0]["" + tab + "_Contont"].ToString();
        title = NewDt.Rows[0]["" + tab + "_Name"].ToString();
    }

    /// <summary>
    /// 加载数据
    /// </summary>
    void LoadData()
    {
                JModel.DBEntities db = new JModel.DBEntities();
                stud = db.CX_Student.FirstOrDefault();
        if (Session["user"] != null)
        {
            stud = (CX_Student)Session["user"];
        }
        else
        {
            TextData.ResonseAlert("您长时间没有任何操作,请重新登录.");
            TextData.Res.Response.Write("<script>window.location.href='Login.aspx';</script>");
        }



        db.Connection.Close();
        db.Dispose();
    }
}